package site.beanyon.now.model.po;

import java.util.Date;

/**
 * 用户信息更新日志持久化对象
 */
public class UserUpdateLogPO {
    /**
     * 主键id
     */
    private Integer id;

    /**
     * 用户id
     */
    private Integer userId;

    /**
     * 变更前
     */
    private String beforeUpdate;

    /**
     * 变更后
     */
    private String afterUpdate;

    /**
     * 创建时间
     */
    private Date createdAt;

    public UserUpdateLogPO() {
    }

    public UserUpdateLogPO(Integer userId, String beforeUpdate, String afterUpdate) {
        this.userId = userId;
        this.beforeUpdate = beforeUpdate;
        this.afterUpdate = afterUpdate;
    }

    public UserUpdateLogPO(Integer id, Integer userId, String beforeUpdate, String afterUpdate, Date createdAt) {
        this.id = id;
        this.userId = userId;
        this.beforeUpdate = beforeUpdate;
        this.afterUpdate = afterUpdate;
        this.createdAt = createdAt;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getBeforeUpdate() {
        return beforeUpdate;
    }

    public void setBeforeUpdate(String beforeUpdate) {
        this.beforeUpdate = beforeUpdate;
    }

    public String getAfterUpdate() {
        return afterUpdate;
    }

    public void setAfterUpdate(String afterUpdate) {
        this.afterUpdate = afterUpdate;
    }

    public Date getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(Date createdAt) {
        this.createdAt = createdAt;
    }

    @Override
    public String toString() {
        return "UserUpdateLogPO{" +
                "id=" + id +
                ", userId=" + userId +
                ", beforeUpdate='" + beforeUpdate + '\'' +
                ", afterUpdate='" + afterUpdate + '\'' +
                ", createdAt=" + createdAt +
                '}';
    }
}
